<!DOCTYPE html>
<html>
<head>
    <title> 智能家居 随心所控</title>
    <meta name="keywords" content="{$site_info.site_seo_keywords|default=''}"/>
    <meta name="description" content="{$site_info.site_seo_description|default=''}">
    <include file="public@head"/>
    <link href="__TMPL__/public/assets/css/slippry/slippry.css" rel="stylesheet">
    <link href="__TMPL__/public/assets/css/banner.css" rel="stylesheet">
    <hook name="before_head_end"/>
</head>
<body class="body-white">
<include file="public@nav"/>

<!-- index-1st 第一屏第一层 -->
<div class="index-1st">
<div id="banner_box" class="banner_box" style="margin-top: 70px">
    <div class="banner_cot">
        <!--放banner页面-->
        <div class="banner_list" id="banner_list">
            <!--第一个页面 天空下的猫老师-->
            <div class="page_box show">
                <div class="bg_box">
             <if condition="isset($img0)"> <a href="#">   <img src="__TMPL__/public/assets/images/sky_xia.jpg" class="sky_xia sky_anim2" /></a>
                    <else/>
                    <a href="{$img0.url}">   <img src="{$img0.image}" class="sky_xia sky_anim2" /></a>
             </if>
                    <img src="image/sky_shang.png" />
                </div>
                <div class="content">
                    <div class="main_box">
                        <div class="sky_cot sky_anim2">
                            <if condition="isset($img0)"> <span style="font-size: 50px;color: #9d8922"></span></if>
                        </div>
                    </div>
                </div>
            </div>
            <!--第二个页面 房间里的猫老师-->
            <div class="page_box">
                <div class="bg_box">
                    <if condition="isset($img1)"> <a href="#">    <img src="__TMPL__/public/assets/images/room_bg2.jpg" /></a>
                    <else/>
                    <a href="{$img0.url}">   <img src="{$img1.image}"/></a>
                    </if>
                </div>
                <div class="content">
                    <div class="main_box">
                        <div class="room_cot">
                            <div class="room_anim">
                                <if condition="isset($img1)"> <span style="font-size: 50px;color: #9d8922"></span></if>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <!--第三个页面 雪中的猫老师-->
            <div class="page_box  ">
                <div class="bg_box">
                    <if condition="isset($img2)"> <a href="#"> <img src="__TMPL__/public/assets/images/snow_bg3.jpg" /></a>
                    <else/>
                    <a href="{$img0.url}">   <img src="{$img2.image}"/></a>
                    </if>
                </div>
                <div class="content">
                    <div class="main_box">
                        <div class="snow_cot snow_anim">
                            <if condition="isset($img3)"><span style="font-size: 50px;color: #9d8922"></span></if>
                        </div>
                    </div>
                </div>
            </div>
            <!--第四个页面 森林中的猫老师-->
            <div class="page_box ">
                <div class="bg_box">
                    <if condition="isset($img3)"> <a href="#">  <img src="__TMPL__/public/assets/images/forest_bg4.jpg" /></a>
                    <else/>
                    <a href="{$img0.url}">   <img src="{$img2.image}"/></a>
                    </if>
                </div>
                <div class="content">
                    <div class="main_box">
                        <div class="forest_cot forest_anim">
                           <if condition="isset($img3)"> <span style="font-size: 50px;color: #9d8922"></span></if>
                        </div>
                    </div>
                </div>
            </div>



        <!--放浮动链接小图标-->
        <div class="product_btns" id="product_btns" style="margin-bottom: 100px;">
            <div class="content">
                <div class="btns_box" id="control_box" style="height: 20px;text-align: center">
                    <a href="#" class="icon_bg icon_show"></a>
                    <a href="#" class="icon_bg"></a>
                    <a href="#" class="icon_bg"></a>
                    <a href="#" class="icon_bg"></a>
                </div>
            </div>
        </div>
    </div>
</div>
</div>
</div>
<!-- index-2st 第二屏 -->
<style>
    .home_system{
    }
    .on1{
        float: left;
        margin-top: 28%;
        margin-left: 10%;
        border-radius: 50px;
        overflow: hidden;
    }
    .bot1{
        background: url("/public/themes/simpleboot3/public/assets/images/123.jpg") no-repeat 0 0;
        height: 60%;
        margin-top: 20px;
    }
</style>
<section class="home_system">
    <div class="hs_container" style="width: 100%">
        <p class="hc_title">丰富、完整的四大全宅智能系统</p>
        <em></em>
        <div class="bot1">
            <div class="on1">
                <img src="__TMPL__/public/assets/images/345.png">
            </div>
            <div class="on1">
                <img src="__TMPL__/public/assets/images/456.png">
            </div>
            <div class="on1">
                <img src="__TMPL__/public/assets/images/567.png">
            </div>
            <div class="on1">
                <img src="__TMPL__/public/assets/images/678.png">
            </div>
        </div>
    </div>
</section>
<section class="home_section">
    <div class="hs_container">
        <p class="hs_title">更简单、实用、安全、可靠的智能家居系统</p>
        <em></em>
        <div class="hs_item hs_one">
            <p class="hi_number">No.1</p>
            <div class="hi_pic"></div>
            <div class="hi_text">
                <p class="hi_title">简单安装</p>
                <p class="hi_txt">智能手动电动一体化</p>
            </div>
        </div>
        <div class="hs_item hs_two">
            <p class="hi_number">No.2</p>
            <div class="hi_pic"></div>
            <div class="hi_text">
                <p class="hi_title">实用便捷</p>
                <p class="hi_txt">更人性化的产品设计更简单的使用方式</p>
            </div>
        </div>
        <div class="hs_item hs_three">
            <p class="hi_number">No.3</p>
            <div class="hi_pic"></div>
            <div class="hi_text">
                <p class="hi_title">安全可靠</p>
                <p class="hi_txt">金融级的智能家居云平台</p>
            </div>
        </div>
        <div class="hs_item hs_four">
            <p class="hi_number">No.4</p>
            <div class="hi_pic"></div>
            <div class="hi_text">
                <p class="hi_title">兼容扩展性强</p>
                <p class="hi_txt">新增设备任意连接跨品牌产品可实现互联互通</p>
            </div>
        </div>
        <div class="hs_item hs_five">
            <p class="hi_number">No.5</p>
            <div class="hi_pic"></div>
            <div class="hi_text">
                <p class="hi_title">超低功耗</p>
                <p class="hi_txt">leaves，稳定、可靠、超低功耗</p>
            </div>
        </div>
    </div>
</section>
<section class="home_banner">
    <div class="hb_block hb_one">
        <div class="hb_container">
            <p class="hc_title">回家模式</p>
            <em></em>
            <p class="hc_title1">一打开门，仿佛有人迎接你回家</p>
            <p class="hc_txt">当你在这座城市努力拼搏，夜班到家，只要用指纹轻轻打开家门，玄关、过道、客厅的灯光全部自动亮起，窗帘缓缓打开，柔和舒适的灯光瞬间映入眼帘，让拼搏的你终于也有了家的温情。</p>
            <div class="hc_pic"></div>
        </div>
    </div>
    <div class="hb_block hb_two">
        <div class="hb_container">
            <p class="hc_title">离家模式</p>
            <em></em>
            <p class="hc_title1">不放过任何一点风吹草动，守护家庭安全</p>
            <p class="hc_txt">当没人在家的时候，布防模式正在运行，玄关、窗户、走廊处的门窗磁传感器和人体传感器一旦触发，智能摄像机将立即录像，并拨打报警电话提醒你，全方位守护家庭安全。</p>
            <div class="hc_pic"></div>
        </div>
    </div>
    <div class="hb_block hb_three">
        <div class="hb_container">
            <p class="hc_title">娱乐模式</p>
            <em></em>
            <p class="hc_title1">在家也能浪漫约会，让家庭成为幸福的港湾</p>
            <p class="hc_txt">当你和爱人想在家里看电影的时候，只要一键开启娱乐模式，DVD、音响、电视全部自动打开，窗帘缓缓拉上，灯光变幻绚丽的色彩，让你在家就有影院版的享受。此外还有烛光晚餐场景、派对场景等任意切换。</p>
            <div class="hc_pic"></div>
        </div>
    </div>
    <div class="hb_block hb_four">
        <div class="hb_container">
            <p class="hc_title">远程控制模式</p>
            <em></em>
            <p class="hc_title1">远程查看，不错过家人的重要时刻</p>
            <p class="hc_txt">出差在外，总惦记着家里亲人？只要打开智家365APP，就可随时随地查看家人动态，还可以通过智能摄像机进行语音通话，不错过家人的重要时刻。</p>
            <div class="hc_pic"></div>
        </div>
    </div>
</section>
<section class="home_app">
    <div class="ha_container">
        <div class="ha_logo"></div>
        <p>兼容、开放的家庭智能控制系统平台</p>
        <em></em>
    </div>
</section>
<section class="case_section">
    <div class="cs_title">
        <p>热门商品</p>
        <em></em>
    </div>
    <div class="featured">
        <div class="container">
            <div class="slide active">
                <img src="{$list[0]['more']['thumbnail']}"/>
                <p class="s_title">{$list[0]['post_title']}</p>
                <p class="s_txt">{$list[0]['post_excerpt']}</p>
                <div class="s_mask"></div>
            </div>
            <volist name="list" id="v">
            <div class="slide">
                <img src="{$v['more']['thumbnail']}"/>
                <p class="s_title">{$v.post_title}</p>
                <p class="s_txt">{$v.post_excerpt}</p>
                <div class="s_mask"></div>
            </div>
            </volist>

        </div>
        <a class="prevslide" href="javascript:void(0)"></a>
        <a class="nextslide" href="javascript:void(0)"></a>
    </div>
</section>
</form>
<include file="public@footer"/>
</body>
</html>
<script>
    (function () {
        //2016-13-10 begin
        var $banner_box = $("#banner_box"),
            $pages = $("#banner_list").find(".page_box"),
            $mainBoxs = $pages.find(".main_box"),
            $bgs = $pages.find(".bg_box img"),
            $controlBox = $("#control_box"),
            $productBtns = $("#product_btns"),
            $controls = $controlBox.find("a");
        var data = {
            pLength: $pages.length,//记录一共有多少个page_box
            curP: 0,
            isCan: true,
            isOnbtn: false,
            fColor: [2, 2, 1, 1, 1],
            dur: 3500,
            cNum: 0
        };

        //自动轮播换页函数
        var cId;
        var pageChange = function (idx) {
            if (data.isOnbtn)
                return;
            if (idx >= -1 && idx < data.pLength && idx != data.curP && data.isCan) {
                data.isCan = false;
                data.cNum++;
                clearInterval(cId);//停止动画
                idx = idx == -1 ? data.pLength - 1 : idx;//条件表达式 真前假后 指向最后一张
                $controls.removeClass("icon_show").eq(idx).addClass("icon_show");
                $pages.eq(data.curP).css({ zIndex: 0 });
                $pages.eq(idx).addClass("show").css({ opacity: 0, zIndex: 1 }).animate({ opacity: 1 }, 400, function () {
                    $pages.eq(data.curP).removeClass("show");
                    $(this).addClass("show");
                    data.isCan = true;
                    data.curP = idx;
                    data.cNum--;
                    if (data.cNum == 0) {
                        //setInterval() 方法会不停地调用函数，直到 clearInterval() 被调用或窗口被关闭。
                        cId = setInterval(function () {
                            pageChange((data.curP + 1) % data.pLength);
                            //% 求余数 当要处理 X % Y时, 如果, X < Y 的话, 回传值就是 X 自己 1 % 4 = 1
                        }, data.dur);//data.dur 是时间
                    }
                });
            }
        }
        //鼠标经过 下方导航
        $controls.on("mouseenter", function () {
            data.isCan = true;
            pageChange($controls.index(this));
            data.isOnbtn = true;
        });
        $controls.on("mouseleave", function () {
            data.isOnbtn = false;
        });

        cId = setInterval(function () {
            pageChange((data.curP + 1) % data.pLength);
        }, data.dur);

        //网页自由缩放  2016-10-12 调整
        var isIE6 = navigator.userAgent.indexOf("MSIE 6.0") > 0;//获取浏览器的版本
        //调整
        //页面自缩放
        var resize = function () {
            var w = $(window).width(),
                h = $(window).height();

            $banner_box.height(h);
            if (w / h < 1920 / 1080) {
                $bgs.height(h).css({ width: "auto", margin: -.5 * h + "px 0 0 " + -.5 * 1920 / 1080 * h + "px" });

            } else {
                $bgs.width(w).css({ height: "auto", margin: -.5 * w * 1080 / 1920 + "px 0 0 " + -.5 * w + "px" });
            }
            resize_img(w, h);//调用函数 改变内容图片大小

            var imgH = $bgs.height();
            $mainBoxs.height(imgH).css("margin-top", -.5 * imgH + "px");
            var cls;
            switch (true) {
                case w >= 1600: { cls = "big_view"; break; }
                case w < 1600 && w >= 1440: { cls = "mid_view"; break; }
                case w < 1440: { cls = "small_view"; break; }
            }
            var ws = $banner_box[0].className;
            if (isIE6 && (ws.indexOf("big") != -1 || ws.indexOf("mid") != -1 || ws.indexOf("small") != -1) && ws.indexOf(cls) == -1)
                location.reload();
            banner_box.className = "banner_box " + cls;
        };
        $(window).resize(resize);
        resize();

        function resize_img(w, h) {
            var snoww = w * 593 / 1920,
                snowh = h * 448 / 1080;
            var roomw = w * 668 / 1920,
                roomh = h * 585 / 1080;
            var forestw = w * 500 / 1920,
                foresth = h * 636 / 1080;
            var skyw = w * 371 / 1920,
                skyh = h * 341 / 1080;
            if (w / h < 1920 / 1080) {
                //$(".snow_cot").height(snowh).css({ width: snowh * 宽 / 高 + "px", margin: "0 0 0" + -.5 * 宽 / 高 * snowh + "px" });
                $(".snow_cot").height(snowh).css({ width: snowh * 593 / 448 + "px", margin: "0 0 180px" + -.5 * 593 / 448 * snowh + "px" });
                $(".room_cot").height(roomh).css({ width: roomh * 668 / 585 + "px", margin: "0 0 180px" + -.5 * 400 / 585 * roomh + "px" });
                $(".forest_cot").height(foresth).css({ width: skyh * 371 / 341 + "px" });
                $(".sky_cot").height(skyh).css({ width: skyh * 371 / 341 + "px" });

            } else {
                //$(".snow_cot").width(snoww).css({ height: snoww * 高 / 宽 + "px", margin: "0 0 0" + -.5 * snoww + "px" });
                $(".snow_cot").width(snoww).css({ height: snoww * 448 / 593 + "px", margin: "0 0 180px" + -.5 * snoww + "px" });
                $(".room_cot").width(roomw).css({ height: roomw * 585 / 668 + "px", margin: "0 0 180px" + -.5 * 400 * roomw / 668 + "px" });
                $(".forest_cot").width(forestw).css({ height: forestw * 636 / 500 + "px", margin: "0 0 180px" + -.5 * forestw + "px" });
                $(".sky_cot").width(skyw).css({ height: skyw * 636 / 500 + "px" });
            }

        }
    })();
    !(function($){
        var height = window.innerHeight ||(document.documentElement&&document.documentElement.clientHeight)||document.body.clientHeight;
        var width = window.innerWidth ||(document.documentElement&&document.documentElement.clientWidth)||document.body.clientWidth;
        var initHeight = 1500 + height - 100;
        var position = (2*height + 200)/4;
        $(".home_banner").height(3*height);
        $(".home_banner .hb_block").height(height);
        $(".home_banner .hb_block .hb_container").css({"padding-top":height*0.50+"px"});
        $(window).resize(function(){
            height = window.innerHeight ||(document.documentElement&&document.documentElement.clientHeight)||document.body.clientHeight;
            $(".home_banner").height(3*height);
            $(".home_banner .hb_block").height(height);
            initHeight = 1500 + height - 100;
        });
        function init(scrollHeight){
            if (scrollHeight >= 200){
                $(".hc_item").addClass('hc_animate');
                $(".hs_item .hi_pic").addClass('hi_animate');
                $(".hs_item .hi_text").addClass('hi_animate');
            }
        }
        $(window).scroll(function(event) {
            var scrollHeight = $(document).scrollTop();
            init(scrollHeight);
            if (scrollHeight < initHeight){
                $(".hb_block").removeClass('hb_curr');
            }
            if(scrollHeight > 200 && scrollHeight < 900){
                $(".hc_item").addClass('hc_animate');
            } else if (scrollHeight >= 1200 && scrollHeight < 1500){
                $(".hs_item .hi_pic").addClass('hi_animate');
                $(".hs_item .hi_text").addClass('hi_animate');
            } else if (scrollHeight >= initHeight && scrollHeight < initHeight + position){
                $(".hb_one").addClass('hb_curr');
                if ($(".hb_two").hasClass('hb_curr')){
                    //往上滑动
                    $(".hb_two").stop(true).css({filter:"alpha(opacity=0)"}).animate({opacity: 0}, 1000,function(){
                        $(this).removeClass('hb_curr');
                    });
                    $(".hb_one").stop(true).css({filter:"alpha(opacity=100)"}).animate({opacity: 1}, 1000);
                } else {
                    $(".hb_one").css({
                        opacity: 1,
                        filter:"alpha(opacity=100)"
                    });
                }
            } else if (scrollHeight >= initHeight + position && scrollHeight < initHeight + 2 * position){
                //往下滑动
                if ($(".hb_one").hasClass('hb_curr')){
                    $(".hb_one").stop(true).css({filter:"alpha(opacity=0)"}).animate({opacity: 0}, 1000,function(){
                        $(this).removeClass('hb_curr');
                    });
                } else if ($(".hb_three").hasClass('hb_curr')){
                    //往上滑动
                    $(".hb_three").stop(true).css({filter:"alpha(opacity=0)"}).animate({opacity: 0}, 1000,function(){
                        $(this).removeClass('hb_curr');
                    });
                }
                $(".hb_two").addClass('hb_curr');
                $(".hb_two").stop(true).css({filter:"alpha(opacity=100)"}).animate({opacity: 1}, 1000);
            } else if (scrollHeight >= initHeight + 2 * position && scrollHeight < initHeight + 3 * position){
                //往下滑动
                if ($(".hb_two").hasClass('hb_curr')){
                    $(".hb_two").stop(true).css({filter:"alpha(opacity=0)"}).animate({opacity: 0}, 1000,function(){
                        $(this).removeClass('hb_curr');
                    });
                } else if ($(".hb_four").hasClass('hb_curr')){
                    //往上滑动
                    $(".hb_four").stop(true).css({filter:"alpha(opacity=0)"}).animate({opacity: 0}, 1000,function(){
                        $(this).removeClass('hb_curr');
                    });
                }
                $(".hb_three").addClass('hb_curr');
                $(".hb_three").stop(true).css({filter:"alpha(opacity=100)"}).animate({opacity: 1}, 1000);
            } else if(scrollHeight >= initHeight + 3 * position && scrollHeight < initHeight + 4 * position){
                if ($(".hb_three").hasClass('hb_curr')){
                    $(".hb_three").stop(true).css({filter:"alpha(opacity=0)"}).animate({opacity: 0}, 1000,function(){
                        $(this).removeClass('hb_curr');
                    });
                    $(".hb_four").stop(true).css({filter:"alpha(opacity=100)"}).animate({opacity: 1}, 1000);
                } else {
                    $(".hb_four").css({
                        opacity: 1,
                        filter:"alpha(opacity=100)",
                        top: 2*height+"px"
                    });
                }
                $(".hb_four").addClass('hb_curr');
                $(".hb_four").css({top: 0});
            } else if(scrollHeight >= initHeight + 4 * position){
                $(".hb_block").removeClass('hb_curr');
                $(".hb_four").css({
                    opacity: 1,
                    filter:"alpha(opacity=100)",
                    top: 2*height+"px"
                });
            }
        });
        $(".home_title a").click(function(){
            $("body").css({"overflow":"hidden"});
            var width = $(window).width();
            var height = $(window).height();
            var src="http://200003613.vod.myqcloud.com/200003613_7dd7631cfa5711e694c071a341bca255.f0.mp4";
            $(".video_modal").fadeIn(300);
            $(".video_modal").append('<video id="really-cool-video" class="video-js" controls preload="auto" autoplay data-setup='+'{ "controls": true, "autoplay": true, "preload": "auto"}'+' style="width:1190px;height:600px"><source src="'+src+'" type="video/mp4" /></video>');
            $(".video_mask").css({"width":width+"px","height":height+"px"});
            $(".video_mask").fadeIn(300);
            $(".video_mask").click(function(){
                $(".video_modal").fadeOut(300);
                $(".video_mask").fadeOut(300);
                $("#really-cool-video").remove();
                $("body").css({"overflow":"auto"});
            });
        });
    })(jQuery);
</script>